define(['app'], function(app) {
	'use strict';

	//实例化方法
	var factory = function(Http) {

		//返回信息
		return {
			getList: function(nPage,act_type,callback,calldone) {
				Http.post({
					method: 'marketing.auction.getlist',
					pagelimit: 10,
					nPage: nPage,
					act_type:act_type
				}, function(result) {
					if(callback)
						callback(result.result,result.process_time);
				}, function(e) {

				}, function() {
					if(calldone){
						calldone();
					}
				})
			},
			//轮播图
			getBannerList: function(callback) {
				Http.post({
					method: 'marketing.banner.getlist',
					act_type:4
				}, function(result) {
					if(callback) {
						callback(result);
					}
				}, function(e) {
					//请求异常
				}, function() {
					
				});
			}
			
		};
	}

	factory.$inject = ['Http'];
	return app.registerService("Panicauction", factory);
});